<?php
use yii\helpers\Html;
use yii\grid\GridView;

/* @var $this yii\web\View */
/* @var $searchModel common\modules\system\models\search\DataDictionaryCategorySearch */
/* @var $dataProvider yii\data\ActiveDataProvider */

$this->title = '数据字典';
$this->params['breadcrumbs'][] = $this->title;
?>

<?= Html::a('新建', ['create'], ['class' => 'btn btn-primary']);?>

    <?= GridView::widget([
        'dataProvider' => $dataProvider,
        'columns' => [
            [
              'class'=>'common\grid\TextIdColumn',
            ],
            [
    			'attribute'=>'name',
    			'format'=>'html',
				'value'=>function ($model,$key,$index,$column)
					{
						
						return Html::a($model->name,['/system/data-dictionary/index','category'=>$model->id]);
					}
			],
            'description',
            [
                'class' => 'yii\grid\ActionColumn'
			],
        ],
    ]); ?>